#include<bits/stdc++.h>
using namespace std;
#define int long long
signed main() {
	int n, x;
	cin >> n;

	bool output = 0;
	int cnt = 0;
	while (cin >> x) {
		while (x--) {
			cnt++;
			cout << output;
			if (cnt % n == 0)
				cout << endl;
		}
		output ^= 1;
	}
	return 0;
}
